<?php
class mcz_Crypt
{
	private static $crypt;
	public static function crypt($string)
	{
		return self::getCrypt()->encrypt($string);
	}

	public static function decrypt($string)
	{
		return self::getCrypt()->decrypt($string);
	}

	private static function getCrypt()
	{
		if(empty(self::$crypt))
		{
			self::$crypt = new Crypt();
			self::$crypt->Mode = Crypt::MODE_HEX;
			self::$crypt->Key  = defined(mcz_KEY) ? mcz_KEY : '!@#$%&*()_+?:';
		}
		return self::$crypt;
	}
}